<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script>

        function over(obj) {
            obj.style.backgroundColor = "red";
        }

        function out(obj) {
            obj.style.backgroundColor = "green";
        }
    </script>
</head>
<body>
<table>
    <tr align="center">
        <td id="t2" onmousemove="over(this);" onmouseout="out(this);">1</td>
        <td id="t1" onmousemove="over(this);" onmouseout="out(this);">2</td>
        <td id="t3" onmousemove="over(this);" onmouseout="out(this);">2</td>
    </tr>
</table>
</body>
</html>